﻿<controls:MetroWindow x:Class="BTM_Client_Application.DeviceViewer.DeviceControlWindow"
                      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                      xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
                      xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
                      xmlns:controls="clr-namespace:MahApps.Metro.Controls;assembly=MahApps.Metro"
                      xmlns:models="clr-namespace:BTM_Client_Application.DeviceViewer"
                      mc:Ignorable="d" 
                      d:DesignHeight="300" d:DesignWidth="300"
                      d:DataContext="{d:DesignInstance models:DeviceControlWindow}"
                      Initialized="DeviceControlWindow_OnInitialized">

    <controls:MetroWindow.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Colours.xaml" />
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Accents/Blue.xaml" />
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Accents/BaseLight.xaml" />
                <ResourceDictionary Source="pack://application:,,,/Styles/ButtonStyles.xaml" />
                <ResourceDictionary Source="pack://application:,,,/Styles/MyResources.xaml" />
                <ResourceDictionary Source="StyleResetters.xaml"/>
                <ResourceDictionary Source="../../Styles/PanoramaStyle.xaml"/>
            </ResourceDictionary.MergedDictionaries>
            <DataTemplate DataType="{x:Type models:DeviceControlModel}">
                <controls:Tile Foreground="White" Title="{Binding Station}" Content="{Binding ControlContainer}" Style="{StaticResource TileStyle1}" />
            </DataTemplate>
        </ResourceDictionary>
    </controls:MetroWindow.Resources>

    <Grid>
        <ScrollViewer>
            <controls:Panorama Name="DevicePanorama" ItemsSource="{Binding Devices}" HeaderFontColor="{DynamicResource AccentColorBrush}" 
                           VerticalAlignment="Stretch" HorizontalAlignment="Stretch" 
                           Foreground="White" FontFamily="Segoe UI"/>
        </ScrollViewer>
    </Grid>
</controls:MetroWindow>
